package com.testmanager.testmananger.shuiyou.strCompare.respository;

import com.testmanager.testmananger.shuiyou.strCompare.domain.SyProjectEntity;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.querydsl.QuerydslPredicateExecutor;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface SyProjectRepository extends JpaRepository<SyProjectEntity,Long>, JpaSpecificationExecutor<SyProjectEntity>
        , QuerydslPredicateExecutor<SyProjectEntity> {

    SyProjectEntity findByName(String projectName);
    SyProjectEntity findById(long id);

    List<SyProjectEntity> findAllByParentId(long parentId);
}
